package com.kylin.system.entity;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.kylin.common.core.entity.DataEntity;
import com.kylin.common.core.validator.constraint.NotRepeat;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;

/**
 * 字典类型表 sys_dict_type
 * 
 * @author wuhao
 * @version 1.0 - 2019-02-11
 */
@Data
@TableName("sys_dict_type")
@NotRepeat(field = "dictType" , message = "字典类型已存在")
public class SysDictType extends DataEntity<SysDictType>
{

    @TableId(type = IdType.AUTO)
    private Long id;

    /** 字典名称 */
    @Excel(name = "字典名称")
    @NotBlank(message = "字典名称不能为空")
    @Size(min = 0, max = 100, message = "字典类型名称长度不能超过100个字符")
    private String dictName;

    /** 字典类型 */
    @Excel(name = "字典类型", width = 20)
    private String dictType;
    

    /** 状态（0正常 1停用） */
    @Excel(name = "状态", dict = "sys_normal_disable")
    private String status;

    /** 备注 */
    private String remarks;

}
